home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Format CD 49
/
Amiga Format CD49 (2000-01-17)(Future Publishing)(GB)(Track 1 of 3)[!][issue 2000-02].iso
/
-serious-
/
sound
/
melodyrecgui
/
melodyrecgui-eng
< prev
next >
Wrap
Text File
|
1999-11-29
|
6KB
|
292 lines
/* $VER: MelodyRec.rexx 2.0.1 (12.11.1999) © mEDi of dSd E-Mail:mEDi_dSd@GMX.DE & Ramboy of Warp9 E-Mail:rby@w-9.de*/
/*
22.01.99 V1.0.1 first version
24.01.99 V1.0.2 2 minor bugs removed by Ramboy@W-9.DE
25.01.99 V1.0.3 first Aminet Version
14.02.99 V1.0.4 english version (RAMBOY) and some Bugs removed (RAMBOY)
07.05.99 V1.0.5 new device name (RAMBOY)
12.11.99 V2.0.1 (RAMBOY)
*/
/* rexxsupport.library öffnen */
IF ~SHOW('LIBRARIES','rexxsupport.library') THEN
IF ~ADDLIB('rexxsupport.library',0,-30,0) THEN DO
say "Could not open the rexxsupport.library "
EXIT(10)
END
Signal On Syntax
Signal On IOErr
Signal off failure
CALL PRAGMA("PRIORITY",1)
/* rexxreqtools.library öffnen */
IF ~SHOW(LIBRARIES,'rexxreqtools.library') THEN
IF ~ADDLIB('rexxreqtools.library',10,-30,0) THEN
EXIT(10)
IF ~SHOW('LIBRARIES','tritonrexx.library') THEN DO
IF ~ADDLIB('tritonrexx.library',5,-30,0) THEN DO
SAY 'Could not open the <tritonrexx.library> !'
EXIT(10)
END
END
OPTIONS RESULTS
Version = "2.0"
Release = "1"
DATE = "12.11.1999"
NL = '0a'x
MainProgramm = "MelodyRec" /* MelodyRec pfade z.B. "sys:pro/MelodyRec" usw. */
main_UNIT = "0" /* def audiounit */
main_AudioName = "melodyaudio.device" /* def audioname */
main_BITS_LIST.0 = 3
main_BITS_LIST.1 = 8
main_BITS_LIST.2 = 16
main_BITS_LIST.3 = 32
call init_windows
app = TR_CREATEAPP('TRCA_Name MelodyRec.rexx',
'TRCA_LongName "MelodyRec GUI © MEDI [_- DSD -_] & RAMBOY [_- W9 -_]"',
'TRCA_Info "MelodyRec GUI"',
'TRCA_Version 'Version,
'TRCA_Release 'Release,
'TRCA_Date 'DATE,
'TAG_END')
IF app ~= '00000000'x THEN DO
window = TR_OPENPROJECT(app,windowtags)
IF window ~= '00000000'x THEN DO
ende = 0
DO WHILE ende ~= 1
CALL TR_WAIT(app,'')
DO WHILE TR_HANDLEMSG(app,'event')
/*say '************'
say event.trm_class
say event.trm_id
say '*************'*/
/* 'TRMS_ACTION' START */
IF event.trm_class = 'TRMS_ACTION' THEN DO
SELECT
/* QUIT */
WHEN event.trm_id = 1 THEN ENDE = 1
/* SELECT new file */
WHEN event.trm_id = 21 THEN call select_new_file
/* RUN */
WHEN event.trm_id = 30 THEN call RUN_melodyREC
/* 'TRMS_ACTION' END */
OTHERWISE
NOP
END
END
IF event.trm_class = 'TRMS_CLOSEWINDOW' THEN
ende = 1
END
END
CALL TR_CLOSEPROJECT(window)
END
CALL TR_DELETEAPP(app)
END
EXIT
/***********************************************************************************/
/**********************************************************************************/
select_new_file:
main_new_files = rtfilerequest(, , "please select new filename", ,"rtfi_buffer=true rtfi_matchpat=(#?")
if main_new_files = "" then return
call TR_SETATTRIBUTE(window,20,'TROB_String',main_new_files)
Return
RUN_melodyREC:
/* FILENAME/A,AUDIONAME/K,AUDIOUNIT/N/K,BITS/ */
main_FILENAME = '"'TR_GetAttribute(window,20,'TROB_String')'"'
main_AUDIONAME = TR_GetAttribute(window,10,'TROB_String')
main_AUDIOUNIT = TR_GetAttribute(window,11,'TROB_String')
dummy = TR_GetAttribute(window,12,'TRAT_Value')+1
main_BITS = main_BITS_LIST.dummy
if main_FILENAME = '"'||'"' | main_AUDIONAME = "" | main_AUDIOUNIT = "" then return
say "RUN" MainProgramm main_FILENAME "audioname" main_AUDIONAME "audiounit" main_AUDIOUNIT "bits" main_BITS
address command "RUN" MainProgramm main_FILENAME "audioname" main_AUDIONAME "audiounit" main_AUDIOUNIT "bits" main_BITS
call rtezrequest( "Press Stop"NL,
"to abort"NL,
"the record",
, " _STOP ","MelodyRec GUI", ,
"rtez_flags=ezreqf_centertext rtez_defaultresponse=0")
address command "kill" "melodyRec"
Return
/* Error Log funktion © 1996-99 mEDi of dSd **********************************/
SYNTAX:
IOERR:
failure:
error_num = rc
error_Sigl = Sigl
if exists("s:Error_text_e.txt") then
call READLINES("s:Error_text_e.txt",error_num,1,"%s %1024c",dummy error_txt_e)
error_log_msg.0 = 8
error_log_msg.1 = "*************************************************"
error_log_msg.2 = "Error "error_num" in Line:" Sigl
error_log_msg.3 = "- Error Line -----------"
error_log_msg.4 = SOURCELINE(sigl)
error_log_msg.5 = "- Description -----------------------------------"
error_log_msg.6 = "English : "error_txt_e.1
error_log_msg.7 = "original: "ERRORTEXT(error_num)
error_log_msg.8 = "programm: MelodyRec.rexx V"Version"."Release" ("DATE")"
if ~WRITEFILE("t:Error.log",error_log_msg,append) THEN
call WRITEFILE("t:Error.log",error_log_msg,)
do i = 1 to error_log_msg.0
say error_log_msg.i
end
if app ~= "APP" then
CALL TR_DELETEAPP(app)
EXIT
INIT_Windows:
windowtags = WindowID(1),
WindowTitle('MelodyRec GUI v'Version||Release" ("DATE")"),
windowPosition(TRWP_DEFAULT),
'VertGroupA',
'Space',
NamedSeparator(' © 1999 mEDi of dSd & Ramboy of W9'),
'Space',
'HorizGroup',
'HorizGroup',
'Space',
text3("AudioName: ") 'Space' StringGadget(main_AudioName,10) 'TRAT_Value 32',
'Space',
'EndGroup',
'Space',
'HorizGroup' ,
'Space',
text3("UNIT:") StringGadget(main_UNIT,11) 'TRAT_Value 2',
'Space',
text3("BITS"),
'Space',
CycleGadget('main_BITS_LIST',1,12),
'Space',
'EndGroup',
'Space',
'EndGroup',
'Space',
'HorizGroupA',
'Space',
text3("File: "),
'Space',
StringGadget("",20) 'TRAT_Value 256',
'Space',
GetFileButton(21),
'Space',
'EndGroup',
'Space',
'HorizGroupS',
'Space',
Button("RUN",30),
'Space',
Button("Quit",1),
'Space',
'EndGroup',
'Space',
'EndGroup',
'EndProject'
return